<%--
    Document   : crear_cheques
    Created on : 24-sep-2011, 9:50:50
    Author     : Yojugracu
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<jsp:useBean id = "conectar" scope = "application" class= "Monetario.ManipulacionMysql"/>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
   "http://www.w3.org/TR/html4/loose.dtd">

<div id="bloquer_cuenta_paso1" class="paso1_cuenta">
    <%
    String paso=request.getParameter("paso");
    if(paso==null){paso="1";}
if(paso.equals("1")){
%>
		<!--  start step-holder -->
		<div id="step-holder">
			<div class="step-no">1</div>
			<div class="step-dark-left"><a href="">Paso 1</a></div>
			<div class="step-dark-right">&nbsp;</div>
			<div class="step-no-off">2</div>
			<div class="step-light-left">Paso 2</div>
			<div class="step-light-right">&nbsp;</div>
			<div class="step-no-off">3</div>
			<div class="step-light-left">Paso 3</div>
			<div class="step-light-round">&nbsp;</div>
			<div class="clear"></div>
		</div>
		<!--  end step-holder -->

		<!-- start id-form -->
		<table border="0" cellpadding="0" cellspacing="0"  id="id-form">
		<tr>
			<th valign="top">No. Cuenta:</th>
			<td>
                            <input  id="input-cuenta-bloqueo" type="text" class="inp-form" />
                        </td>
			<td>
                            <div id="div-cuenta-left" class="error-left" style="display:none"></div>
                            <div id="div-cuenta-inner" class="error-inner" style="display:none">Este campo es requerido</div>
			</td>
		</tr>
                <tr>
                    <th valign="top">Declarar:</th>
                    <td>
                    <select id="declarado" class="styledselect_form_1">
                            <option value="1">Activar</option>
                            <option value="2">Cancelar</option>
                            <option value="3">Embargadar</option>
                            <option value="4">Bloquear</option>
                    </select>
                    </td>
                    <td></td>
                </tr>
		<tr>
                   <br>
		<td><br></td>
	</tr>
	<tr>
		<th>&nbsp;</th>
	<!--	<td valign="top">
                    <br>
                    <input type="button" value="" class="form-submit" onclick="crear_cuenta_paso2();" />
			<input type="button" value="cancelar" class="form-reset" onclick="retornar_pagina_inicio();" />
		</td>
		<td><br></td>
 !-->
	</tr>
	</table>
	<!-- end id-form  -->
        		<table border="0" cellpadding="0" cellspacing="0"  id="id-form">
        <tr>
		<th>&nbsp;</th>
		<td valign="top">
			<input type="button" value="" class="form-submit" onclick="bloquear_cuenta_paso2();" />
			<input type="button" value="regresar" class="form-reset" Onclick="retornar_pagina_inicio();" />
		</td>
		<td></td>
	</tr>
	</table>
<%
}
else{
    String cuenta=request.getParameter("cuenta");
    String declarado=request.getParameter("declarado");
    if(cuenta!=null)
        conectar.bloquear_cuenta(cuenta,declarado);

    %>
    		<div id="step-holder">
			<div class="step-no-off">1</div>
			<div class="step-light-left"><a href="">Paso 1</a></div>
			<div class="step-light-right">&nbsp;</div>
			<div class="step-no">2</div>
			<div class="step-dark-left">Paso 2</div>
			<div class="step-dark-right">&nbsp;</div>
			<div class="step-no-off">3</div>
			<div class="step-light-left">Paso 3</div>
			<div class="step-light-round">&nbsp;</div>
			<div class="clear"></div>
		</div>
        
    <%
    if(declarado.equals("2")){
        out.println("<h2>La cuenta ha sido cancelada exitosamente.</h2>");
    }
    else if(declarado.equals("3")){
        out.println("<h2>La cuenta ha sido embargada exitosamente.</h2>");
    }
    else if(declarado.equals("4")){
        out.println("<h2>La cuenta ha sido bloqueada exitosamente.</h2>");
    }
    else if(declarado.equals("1")){
        out.println("<h2>La cuenta ha sido activada exitosamente.</h2>");
    }
}
%>

</div>
